Skip to content

feat(frame-view): the frame.surface view kind — a minimal provider (architect#224) - #31

Merged
fts-forge[bot] merged 2 commits into
mainfrom
feat/sta-653-frame-surface
Nov 4, 2026
Merged

fts-forge[bot] merged 2 commits into
mainfrom
feat/sta-653-frame-surface

Conversation

@fts-forge

@fts-forge fts-forge Bot commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

The frame.surface view kind's provider (architect#224, STA-653): frame-surface, a process extension whose view shows a Frame document, live-bound and hot-reloaded.

What it does

  • The document says what moves it. surface::catalog_of turns each param-bound control into a param (0–100 %, named by its control) and each stream-bound control into a level feed (dB). The built-in document (surfaces/knob-meter.frame) is a knob on surface/drive and a meter on level.
  • Action List actions (extension.toml), reachable from ⌘K, MCP and the CLI:
    • FRAME_SURFACE_LOAD {path} shows a .frame file and watches it.
    • FRAME_SURFACE_PARAM_SET {addr, value 0..1} and FRAME_SURFACE_FEED {id, values: [dB]} are mutating.
    • FRAME_SURFACE_STATE is read-only and returns {document, loads, error, params:[{addr,name,value}], feeds:[{id,name,values}]}.
  • Hot reload. A save to the loaded file reloads it within 200 ms. Params and feeds that are still present keep their values. A save that doesn't parse keeps the surface as it was and reports why in error.
  • The view: the knob can be dragged with the pointer, which moves the param. Each param also has −/+ buttons, and the view shows the document path and any error.
  • FRAME_SURFACE_DOCUMENT=<path> loads a document at start-up.

The core frame crate is unchanged and still has no architect dependency.

Checks

  • nix develop -c cargo fmt --check: exit 0.
  • nix develop -c cargo clippy --workspace --all-targets: exit 0, no warnings.
  • cargo test --test frame_view (crates/frame-view): 7 passed. They cover the catalog from the document, painting params and feeds, a pointer drag turning the knob up, reload keeping values, unknown addr/id errors, and shown::load with save-triggered hot reload (including a save that doesn't parse).
  • Skipped: the full local CI and just recipes beyond these.

Merge this before FastTrackStudios/architect#261, which drives these actions from the lab.

🤖 Generated with Claude Code

…rchitect#224)

A process extension (frame-surface) whose view, of the frame.surface
kind, is a knob and a meter from a Frame document (surfaces/knob-meter.frame)
drawn as an inline svg; FRAME_SURFACE_SET / FRAME_SURFACE_STATE move and
read it. Architect's lab shows it in its Embedded views gallery (STA-653).

Co-Authored-By: Claude Code <noreply@anthropic.com>
…loaded (architect#224)

frame-surface now shows a Frame document rather than a fixed knob and
meter. The document's controls say what moves it: each param-bound control
is a param, each stream-bound control a feed (`surface::catalog_of`).

- FRAME_SURFACE_LOAD {path} shows a `.frame` file and watches it; a save
  reloads it, keeping the values of the params and feeds it still has. A
  save that does not parse keeps the surface and reports why in `error`.
- FRAME_SURFACE_PARAM_SET {addr, value} and FRAME_SURFACE_FEED {id, values}
  move it; FRAME_SURFACE_STATE reads it. These are Action List actions, so
  MCP and the CLI drive them.
- The view's knob can be dragged; the drag moves the param.
- FRAME_SURFACE_DOCUMENT loads a document at start-up.

Co-Authored-By: Claude Code <noreply@anthropic.com>
fts-forge Bot added a commit that referenced this pull request Nov 4, 2026
…d, role saves, themed surface chrome (#35)

Frame's runtime theme engine, as Studio uses it locally (studio#377).
Includes #31 (the \`frame.surface\` view kind), which this line was
built on; merge that first or close it in favour of this.

- **ThemeHost** (\`crates/frame/src/theme/host.rs\`): layered themes,
last-good live reload, versioned publication, agent actions;
host-rendered slot geometry and target hit testing (#33).
- **frame-doc / frame-editor:** Frame data on figcraft nodes; editor
documents compile as themes and publish to a ThemeHost safely; the
background live theme editor selects and edits roles and saves them to
their source layers (\`docs/theme-save-concurrency.md\` states what the
save does not yet guard against).
- **fix(frame-doc):** fontique 0.12 aligned to \`fontconfig-dlopen\` on
Linux where figcraft enters the graph — \`cargo check --workspace\`
failed with unresolved \`FcCharSet*\` imports; consumers (Studio) no
longer carry the workaround.
- **frame-view:** the surface pane's heading, notes and buttons read the
host's CSS variables (architect puts the app's live \`:root\` theme into
a process view's document), so the pane follows the app's theme.

Checked locally against architect/Studio/Keyflow local checkouts:
\`cargo check --workspace --all-targets\`; frame-surface drawn in
architect's lab in a real window, following light and dark themes;
Studio's themed window reskinned and live-reloaded.

Open: the cooperative save lock (designed, not built); lowering is not
incremental (85.7 ms for 2,000 rectangles).

🤖 Generated with [Claude Code](https://claude.com/claude-code)
@fts-forge

fts-forge Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor Author

Merged as part of #35, which was built on this branch's frame-surface commits.

@fts-forge
fts-forge Bot merged commit 4b3d98a into main Nov 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants